<template>
  <div class="">
    <div class="workTitle">安全措施</div>
    <div class="formBox">
      <div class="formItem">
        <div class="cellCss" @click="showDialog = true">
          <div class="cellCssContent">
            <div class="left">安全措施确认</div>
            <div class="right">></div>
          </div>
        </div>
      </div>
    </div>

    <div class="workTitle">分析项目数据</div>

    <div class="formBox">
      <div
        class="formItem"
        v-for="item in formInfoObj.gasSampleList"
        :key="item.id"
      >
        <van-cell title="分析项目:">
          <template #default>
            {{ item.gasName }}
          </template>
        </van-cell>

        <!-- <van-cell title="合格标准:">
          <template #default>
            <div>{{ item.passStandard }}</div>
          </template>
        </van-cell> -->
        <van-cell title="结果值:">
          <template #default>
            <div>{{ item.analysisResult }}</div>
          </template>
        </van-cell>
        <van-cell title="分析时间:">
          <template #default>
            {{ item.analysisTime }}
          </template>
        </van-cell>
        <div class="cellCss">
          <div class="cellCssContent">
            <div class="left">分析人：</div>
            <div class="right">
              {{ item.analysisUser }}
            </div>
          </div>
          <!-- <div class="cellCssContent2">
            <div>签字：</div>
            <div>
              <img
                class="showImg"
                :src="formInfoObj.analysisOpinion?.[0].peopleImage"
                alt=""
              />
            </div>
          </div> -->
        </div>
      </div>
    </div>
    <van-popup closeable round v-model="showDialog" position="bottom">
      <div class="popBox">
        <div class="popTitle">安全措施确认</div>
        <div
          class="formItem"
          v-for="item in formInfoObj.ticketSecurityMethods"
          :key="item.id"
        >
          <div class="cellCss">
            <div class="cellCssTitle">
              {{ item.name }}
            </div>
            <div class="cellCssContent">
              <div class="right">
                涉及：
                <span v-if="item.isInvolved == 1" style="color: #0077ff"
                  >是</span
                >
                <span v-else style="color: #ff6e00">否</span>
              </div>
            </div>
          </div>
        </div>
      </div>
    </van-popup>
  </div>
</template>

<script>
export default {
  name: 'topForm2',
  props: {
    wordId: {
      type: String,
      default: () => '',
    },
    formInfoObj: {
      type: Object,
      default: () => ({
        printingJobId: '',
        fireJobContent: '',
        firePlace: '',
        applicantUnit: '',
        firePeople: '',
        principalOpinion: [
          {
            peopleName: '',
          },
        ],
        guardianOpinion: [
          {
            peopleName: '',
          },
        ],
        measureOpinion: [
          {
            peopleName: '',
          },
        ],
        safetyerOpinion: [
          {
            peopleName: '',
          },
        ],
        fireBeginTime: '',
        fireEndTime: '',
        fireGrade: '',
        relevanceJobId: '',
      }),
    },
    code: {
      type: String,
      default: () => '',
    },
  },
  components: {},
  data() {
    return {
      showDialog: false,
    }
  },
  methods: {},
  mounted() {},
  watch: {},
  computed: {},
  filters: {},
}
</script>

<style scoped lang="scss">
.popBox {
  background-color: #f5f6f7;
  padding: 10px;
  .popTitle {
    font-size: 16px;
    color: #313235;
    font-weight: bold;
    padding: 10px;
  }
  .formItem {
    background-color: #fff;
    margin-bottom: 10px;
    border-radius: 5px;
    padding: 5px;
  }
}
.showImg {
  width: 100%;
}
</style>
